//
//  MTool.h
//  SSC
//
//  Created by 红沙尘 on 17/6/9.
//  Copyright © 2017年 红沙尘. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface MTool : NSObject

+ (NSString *)caizhongWithType:(CaipiaoType)otype;

+ (NSString *)longhuheCode:(NSString *)code;

+ (NSString *)dingweidanCode:(NSString *)code place:(NSString *)place;

+ (NSString *)MD5:(NSString *)str;

+ (NSString *)formartDate:(NSString *)dateStr;

+ (int)zuheFromM:(int)m n:(int)n;

+ (int)pailieFromM:(int)m n:(int)n;

+ (NSString *)dateToString:(NSDate *)aDate;

+ (BOOL)judgePassWordLegal:(NSString *)pass;

+ (CGFloat)adapterHeight:(CGFloat)height;

+ (void)showMessage:(NSString *)message inView:(UIView *)view;

+ (void)showMessage:(NSString *)message inView:(UIView *)view complete:(void(^)(void))complete;

+ (void)showAlertController:(UIViewController *)controller
                    message:(NSString *)message;

+ (UIFont *)fontOfSize:(CGFloat)size;

+ (CGSize)sizeWithText:(NSString *)text font:(UIFont *)font constrainedToSize:(CGSize)size;

@end
